import { axios } from '@/utils/request'

export function getSysOpenAccountList(parameter) {
  return axios({
    url: '/sys/bank/pageQueryAccountInfo',
    method: 'post',
    data:parameter
  })
}
export function sysAddParkCmbOpenAccount(parameter) {
  return axios({
    url: '/sys/bank/cmbParkOpenAccount',
    method: 'post',
    data:parameter
  })
}
export function sysAddEnterpriseCmbOpenAccount(parameter) {
  return axios({
    url: '/sys/bank/cmbEnterpriseOpenAccount',
    method: 'post',
    data:parameter
  })
}
export function sysAddEnterpriseParkSeaOpenAccount(parameter) {
  return axios({
    url: '/sys/bank/bhOpenAccount',
    method: 'post',
    data:parameter
  })
}
export function sysCancelBankAccount(parameter) {
  return axios({
    url: '/sys/bank/closeBankAccount',
    method: 'post',
    data:parameter
  })
}
export function sysOpenAccountBalance(id) {
  id = id !== undefined ? id : '';
  return axios({
    url: '/sys/bank/bankBalanceQuery?id='+id,
    method: 'get'
  })
}
export function sysAddEnterpriseCmbPayAccount(parameter) {
  return axios({
    url: '/sys/bank/cmbAddPaymentAccount',
    method: 'post',
    data:parameter
  })
}
export function getSysEnterpriseCmbPayAccount(id) {
    id = id !== undefined ? id : '';
    return axios({
        url:`/sys/bank/listCmbPaymentAccount?id=${id}`,
        method: 'get',
    })
}
export function getMyAccountList() {
  return axios({
    url: '/sys/bank/queryMyAccount',
    method: 'get'
  })
}
export function applyCash(params) {
  return axios({
    url: '/sys/bank/visTransferOut',
    method: 'get',
    params
  })
}
export function cashSendCode() {
  return axios({
    url: '/sys/bank/visGetOTP',
    method: 'get'
  })
}
export function sysAddEnterprisePayOpenAccount(parameter) {
  return axios({
    url: '/sys/bank/aliPayEnterpriseOpenAccount',
    method: 'post',
    data:parameter
  })
}
export function sysAddParkPayOpenAccount(parameter) {
  return axios({
    url: '/sys/bank/aliPayParkOpenAccount',
    method: 'post',
    data:parameter
  })
}
export function sysParkPaySign(parameter) {
  return axios({
    url: '/sys/bank/aliPayParkSign',
    method: 'post',
    data:parameter
  })
}